class ProgramLocationTablesController < ApplicationController
  def index
    @program_location_tables = ProgramLocationTable.all
  end

  def show
    @program_location_table = ProgramLocationTable.find(params[:id])
  end

  def new
    @program_location_table = ProgramLocationTable.new
  end

  def create
    @program_location_table = ProgramLocationTable.new(params[:program_location_table])
    if @program_location_table.save
      redirect_to @program_location_table, :notice => "Successfully created program location table."
    else
      render :action => 'new'
    end
  end

  def edit
    @program_location_table = ProgramLocationTable.find(params[:id])
  end

  def update
    @program_location_table = ProgramLocationTable.find(params[:id])
    if @program_location_table.update_attributes(params[:program_location_table])
      redirect_to @program_location_table, :notice  => "Successfully updated program location table."
    else
      render :action => 'edit'
    end
  end

  def destroy
    @program_location_table = ProgramLocationTable.find(params[:id])
    @program_location_table.destroy
    redirect_to program_location_tables_url, :notice => "Successfully destroyed program location table."
  end
end
